file_out = NULL;
}
- file_out = xfopen(tmpname, "w", MYNAME);
+ file_out = xfopen(tmpname, "wb", MYNAME);
xfree(tmpname);
ozi_track_hdr(const route_head * rte)
{
static char *ozi_trk_header =
- "OziExplorer Track Point File Version 2.1\n"
- "WGS 84\n"
- "Altitude is in Feet\n"
- "Reserved 3\n"
- "0,2,255,ComplimentsOfGPSBabel,0,0,2,8421376\n"
- "0\n";
+ "OziExplorer Track Point File Version 2.1\r\n"
+ "WGS 84\r\n"
+ "Altitude is in Feet\r\n"
+ "Reserved 3\r\n"
+ "0,2,255,ComplimentsOfGPSBabel,0,0,2,8421376\r\n"
+ "0\r\n";
ozi_openfile(ozi_ofname);
fprintf(file_out, ozi_trk_header);
alt_feet = (waypointp->altitude * 3.2808);
}
- fprintf(file_out, "%.6f,%.6f,0,%.0f,%.5f,,\n",
+ fprintf(file_out, "%.6f,%.6f,0,%.0f,%.5f,,\r\n",
waypointp->latitude, waypointp->longitude, alt_feet, ozi_time);
}
ozi_route_hdr(const route_head * rte)
{
static char *ozi_route_header =
- "OziExplorer Route File Version 1.0\n"
- "WGS 84\n"
- "Reserved 1\n"
- "Reserved 2\n";
+ "OziExplorer Route File Version 1.0\r\n"
+ "WGS 84\r\n"
+ "Reserved 1\r\n"
+ "Reserved 2\r\n";
/* prologue on 1st pass only */
if (route_out_count == 0) {
* R, 1, ICP GALHETA,, 16711680
*/
- fprintf(file_out, "R,%d,%s,%s,\n",
+ fprintf(file_out, "R,%d,%s,%s,\r\n",
route_out_count,
rte->rte_name ? rte->rte_name : "",
rte->rte_desc ? rte->rte_desc : "");
* W,1,7,7,007,-25.581670,-48.316660,36564.54196,10,1,4,0,65535,TR ILHA GALHETA,0,0
*/
- fprintf(file_out, "W,%d,%d,,%s,%.6f,%.6f,%.5f,0,1,3,0,65535,%s,0,0\n",
+ fprintf(file_out, "W,%d,%d,,%s,%.6f,%.6f,%.5f,0,1,3,0,65535,%s,0,0\r\n",
route_out_count,
route_wpt_count,
waypointp->shortname ? waypointp->shortname : "",
index++;
fprintf(file_out,
- "%d,%s,%.6f,%.6f,%.5f,%d,%d,%d,%d,%d,%s,%d,%d,%d,%.0f,%d,%d,%d\n",
+ "%d,%s,%.6f,%.6f,%.5f,%d,%d,%d,%d,%d,%s,%d,%d,%d,%.0f,%d,%d,%d\r\n",
index, shortname, wpt->latitude, wpt->longitude, ozi_time, 0,
1, 3, 0, 65535, description, 0, 0, 0, alt_feet, 6, 0, 17);
data_write(void)
{
static char *ozi_wpt_header =
- "OziExplorer Waypoint File Version 1.1\n"
- "WGS 84\n"
- "Reserved 2\n"
- "Reserved 3\n";
+ "OziExplorer Waypoint File Version 1.1\r\n"
+ "WGS 84\r\n"
+ "Reserved 2\r\n"
+ "Reserved 3\r\n";
track_out_count = route_out_count = 0;
-OziExplorer Waypoint File Version 1.1
-WGS 84
-Reserved 2
-Reserved 3
-1,GCEBB,35.972033,-87.134700,25569.00000,0,1,3,0,65535,Mountain Bike Heaven by susy1313,0,0,0,0,6,0,17
-2,GC1A37,36.090683,-86.679550,25569.00000,0,1,3,0,65535,The Troll by a182pilot & Family,0,0,0,0,6,0,17
-3,GC1C2B,35.996267,-86.620117,25569.00000,0,1,3,0,65535,Dive Bomber by JoGPS & family,0,0,0,0,6,0,17
-4,GC25A9,36.038483,-86.648617,25569.00000,0,1,3,0,65535,FOSTER by JoGPS & Family,0,0,0,0,6,0,17
-5,GC2723,36.112183,-86.741767,25569.00000,0,1,3,0,65535,Logan Lighthouse by JoGps & Family,0,0,0,0,6,0,17
-6,GC2B71,36.064083,-86.790517,25569.00000,0,1,3,0,65535,Ganier Cache by Susy1313,0,0,0,0,6,0,17
-7,GC309F,36.087767,-86.809733,25569.00000,0,1,3,0,65535,Shy's Hill by FireFighterEng33,0,0,0,0,6,0,17
-8,GC317A,36.057500,-86.892000,25569.00000,0,1,3,0,65535,GittyUp by JoGPS / Warner Parks,0,0,0,0,6,0,17
-9,GC317D,36.082800,-86.867283,25569.00000,0,1,3,0,65535,Inlighting by JoGPS / Warner Parks,0,0,0,0,6,0,17
+OziExplorer Waypoint File Version 1.1\r
+WGS 84\r
+Reserved 2\r
+Reserved 3\r
+1,GCEBB,35.972033,-87.134700,25569.00000,0,1,3,0,65535,Mountain Bike Heaven by susy1313,0,0,0,0,6,0,17\r
+2,GC1A37,36.090683,-86.679550,25569.00000,0,1,3,0,65535,The Troll by a182pilot & Family,0,0,0,0,6,0,17\r
+3,GC1C2B,35.996267,-86.620117,25569.00000,0,1,3,0,65535,Dive Bomber by JoGPS & family,0,0,0,0,6,0,17\r
+4,GC25A9,36.038483,-86.648617,25569.00000,0,1,3,0,65535,FOSTER by JoGPS & Family,0,0,0,0,6,0,17\r
+5,GC2723,36.112183,-86.741767,25569.00000,0,1,3,0,65535,Logan Lighthouse by JoGps & Family,0,0,0,0,6,0,17\r
+6,GC2B71,36.064083,-86.790517,25569.00000,0,1,3,0,65535,Ganier Cache by Susy1313,0,0,0,0,6,0,17\r
+7,GC309F,36.087767,-86.809733,25569.00000,0,1,3,0,65535,Shy's Hill by FireFighterEng33,0,0,0,0,6,0,17\r
+8,GC317A,36.057500,-86.892000,25569.00000,0,1,3,0,65535,GittyUp by JoGPS / Warner Parks,0,0,0,0,6,0,17\r
+9,GC317D,36.082800,-86.867283,25569.00000,0,1,3,0,65535,Inlighting by JoGPS / Warner Parks,0,0,0,0,6,0,17\r